
package com.thti.mecool.client.command.send.work;

import com.thti.mecool.client.protocol.GetPageProtocol;
import com.thti.mecool.client.protocol.work.AddWorkmemo;
import com.thti.mecool.client.protocol.work.DeleteWorkmemo;
import com.thti.mecool.client.protocol.work.UpWorkmemo;
import com.thti.mecool.client.service.Protocol;
import com.thti.mecool.client.service.ThtiService;

public class WorkmemoSend {

	public static void addWorkmemo(AddWorkmemo addWorkmemo) {
		
		ThtiService.sendProtocol(Protocol.getAddWorkmemo,addWorkmemo);
	}

	public static void deleteWorkmemo(String  memoId,String userLoginName) {
		DeleteWorkmemo deleteWorkmemo=new DeleteWorkmemo();
		deleteWorkmemo.setMemoId(memoId);
		deleteWorkmemo.setUserLoginName(userLoginName);
		ThtiService.sendProtocol(Protocol.getDeleteWorkmemo,deleteWorkmemo);
	}
	public static void updateWorkmemo(UpWorkmemo upWorkmemo) {

		ThtiService.sendProtocol(Protocol.getUpdateWorkmemo,upWorkmemo);
	}
	public static void searchWorkmemo(String userLoginName, int page, int size) {
		GetPageProtocol getPageProtocol = new GetPageProtocol();
		getPageProtocol.setUserLoginName(userLoginName);
		getPageProtocol.setPage(page);
		getPageProtocol.setSize(size);
		ThtiService.sendProtocol(Protocol.getWorkmemo, getPageProtocol);

	}

}
